package cn.lzy.demo;

import cn.lzy.demo.service.AccountService;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;

/**
 * @Description  使用 TransactionTemplate 进行事务管理
 * @Author lzy
 * @Date 2023/12/27 23:17
 * @Version
 **/
public class TestDemo02OfTransactionTemplate {


    public static void main(String[] args) {
        AnnotationConfigApplicationContext ctx = new AnnotationConfigApplicationContext(JavaConfig.class);
        AccountService accountService = ctx.getBean(AccountService.class);
        accountService.transferMoney2("lzy", "yss", 100.0);
    }
}
